package 流程控制.循环结构;

public class while学习 {
    public static void main(String[] args) {
        int i= 0;
        int sum = 0;
        while (i<100){
            i++;
            sum = i + sum;
            System.out.println(i);
        }
        System.out.println(sum);
    }
}
